<template>
  <div class="posttable">
    <el-row style="margin-bottom: 10px;">
      <el-col :span="24" style="padding-right: 30px;padding-left: 40px;margin-top: 10px;">
        <el-row class="bot">
          <el-col style="margin-bottom: 20px;">
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">姓名</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.name}}</p>
                </el-col>
              </el-row>
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">人员资质级别</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.qualificationLevel}}</p>
                </el-col>
              </el-row>
  
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">性别</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.sex}}</p>
                </el-col>
              </el-row>
  
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">民族</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.nation}}</p>
                </el-col>
              </el-row>
  
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">出生年月</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.birth | converTime("YYYY-MM")}}</p>
                </el-col>
              </el-row>
            </el-col>
          </el-col>

          <el-col style="margin-bottom: 20px;">
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">现居住地</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.area}}</p>
                </el-col>
              </el-row>
  
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">婚姻状况</p>
                </el-col>
                <el-col>
                  <p class="text" >{{info.resumePerson.marital}}</p>
                </el-col>
              </el-row>
            </el-col>
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">联系邮箱</p>
                </el-col>
                <el-col>
                  <p class="text" >{{info.resumePerson.mail}}</p>
                </el-col>
              </el-row>
            </el-col>
            <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">联系方式</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.phone}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">工作年限</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.workYear}}</p>
                  </el-col>
                </el-row>
              </el-col>
          </el-col>
          <el-col  style="margin-bottom: 20px;">
            <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">开始工作时间</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.workStart | converTime("YYYY-MM")}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">从事相关领域时间</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.workTime}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">到岗时间</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.arriveTime }}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">毕业时间</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.gurateTime | converTime("YYYY-MM")}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">全日制</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.fullTime}}</p>
                  </el-col>
                </el-row>
              </el-col>
          </el-col>
          <el-col style="margin-bottom: 20px;">
            <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">毕业院校</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.gurateSchool}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">专业</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.major}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">学历</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.guration}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">学位</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.degree}}</p>
                  </el-col>
                </el-row>
              </el-col>
              <el-col style="width:20%">
              <el-row>
                  <el-col>
                    <p class="title">职业资格证书</p>
                  </el-col>
                  <el-col>
                    <p class="text" >{{info.resumePerson.certificate}}</p>
                  </el-col>
                </el-row>
              </el-col>
          </el-col>
          <el-col style="margin-bottom: 20px;">
            <el-col style="width:20%">
              <el-row>
                <el-col>
                  <p class="title">应聘职位</p>
                </el-col>
                <el-col>
                  <p class="text">{{info.resumePerson.postName}}</p>
                </el-col>
              </el-row>
  
            </el-col>
          </el-col>
        </el-row>

        <el-row class="bot"  >
          <el-col  style="width:50%">
            <el-col>
              <p class="title">职业技能</p>
            </el-col>
            <el-col :span="11"  style="margin-bottom: 20px;">
              <p class="text" v-html="info.resumePerson.vocational">
              </p>
            </el-col>
          </el-col>
          <el-col  style="width:50%">
            <el-col>
              <p class="title">自我评价</p>
            </el-col>
            <el-col :span="11">
              <p class="text" v-html="info.resumePerson.evaluation">
              </p>
            </el-col>
          </el-col>
        </el-row>
        <el-row >
          
 
            <!--学校信息部分-->
            <el-col  class="bot">
              <el-row v-for="(item1,index1) in info.resumeSchools" :key="index1" class="bot">
                <el-col v-if="item1.schoolName">
                  <div class="Line"></div>
                </el-col> 
                <el-col style="width:20%"  v-if="item1.schoolName">
                  <el-col>
                    <p class="title">学校名称</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item1.schoolName}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%" v-if="item1.schoolTimea">
                  <el-col>
                    <p class="title">时间</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item1.schoolTimea | converTime("YYYY-MM")}}——{{item1.schoolTimeb}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%" v-if="item1.schoolMajor">
                  <el-col>
                    <p class="title">专业</p>
                  </el-col>
                  <el-col>
                    <p class="text word">{{item1.schoolMajor}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%" v-if="item1.schoolGruation">
                  <el-col>
                    <p class="title">学历</p>
                  </el-col>
                  <el-col>
                    <p class="text word">{{item1.schoolGruation}}</p>
                  </el-col>
                </el-col>
              </el-row>
            </el-col>
            <!--项目信息部分-->
            <el-col  class="bot">
              <el-row v-for="(item2,index2) in info.resumeProjects" :key="index2" class="bot">
                <el-col v-if="item2.projectName">
                  <div class="Line"></div>
                </el-col> 
                <el-col style="width:20%">
                  <el-col>
                    <p class="title">项目名称</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item2.projectName}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%">
                  <el-col>
                    <p class="title">项目时间</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item2.projectTimea | converTime("YYYY-MM")}}——{{item2.projectTimeb}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%">
                  <el-col>
                    <p class="title">担任职位</p>
                  </el-col>
                  <el-col>
                    <p class="text word">{{item2.projectPost}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:40%">
                  <el-col>
                    <p class="title">项目描述</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item2.projectIntroduction}}</p>
                  </el-col>
                </el-col>
              </el-row>
            </el-col>
            <!--工作信息部分-->
            <el-col  class="bot">
              <el-row v-for="(item3,index3) in info.resumeWorks" :key="index3" class="bot">
                <el-col v-if="item3.workName">
                  <div class="Line"></div>
                </el-col> 
                <el-col style="width:20%" v-if="item3.workName">
                  <el-col>
                    <p class="title">工作单位</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item3.workName}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%" v-if="item3.workTimea">
                  <el-col>
                    <p class="title">工作时间</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item3.workTimea | converTime("YYYY-MM")}}——{{item3.workTimeb}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:20%" v-if="item3.workPost">
                  <el-col>
                    <p class="title">担任职位</p>
                  </el-col>
                  <el-col>
                    <p class="text word">{{item3.workPost}}</p>
                  </el-col>
                </el-col>
                <el-col style="width:40%" v-if="item3.workIntroduction">
                  <el-col>
                    <p class="title">工作描述</p>
                  </el-col>
                  <el-col>
                    <p class="text">{{item3.workIntroduction}}</p>
                  </el-col>
                </el-col>
              </el-row>
            </el-col>
        
        </el-row>
      </el-col>
    </el-row>
  </div>
</template>
<script>
  import axios from 'axios'
  import qs from 'qs'
  export default{
    name: 'persondetail',
    props: {
      detailCode: {
        type: Object
      }
    },
    data(){
      return {
        id: null,
        info: {
          resumePerson :{},
          resumeSchools:{},
          resumeProjects:{},
          resumeWorks:{}
        },
        show : true
      }
    },
    created(){

      this.id = this.detailCode.id;

      this.getdetail()
    },
    methods: {
      getdetail(){
        axios.post(this.url + '/peopleResume/selPeopleResumeByid',
           qs.stringify(
               {
                 id : this.id
               }
           )
        ).then(res => {
          this.unlogin(res.data.code);
          if(res.data.code == 200){
            this.info  = res.data.data;
            if(this.info.customerDto.unifiedInter == 'N'){
              this.show = false;
            }else{
              this.show = true;
            }
          }

        })
      }
    }
  }
</script>
<style scoped>
  .title {
    color: #757575;
    margin-bottom: 10px;
    font-size: 14px;
  }

  .text {
    color: #333333;
    font-weight: 700;
    font-size: 14px;
    word-break: break-all;
    white-space: pre-line;
  }

  .bot {
    margin-bottom: 30px;
  }

  .Line {
    border: 0.5px solid #e8e8e8;
    margin-bottom: 30px;
  }
 
  @media screen and (min-width:1200px) and (max-width:1900px){
    .word{
      word-break: break-all;
      width: 200px;
    }
  }
</style>
